import { S } from '../s';
import { IPSSysMsgTempl } from './ipssys-msg-templ';
import { IPSLanguageRes } from '../res/ipslanguage-res';
import { PSModelObjectImpl } from '../psmodel-object-impl';

export class PSSysMsgTemplImpl
  extends PSModelObjectImpl
  implements IPSSysMsgTempl
{
  get codeName(): string {
    return this.M.codeName;
  }

  get content(): string {
    return this.M.content;
  }

  protected contentpslanguageres: IPSLanguageRes;
  getContentPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.contentpslanguageres ||
      (this.contentpslanguageres = this.fillObjectModel(
        S._276,
        this.M.getContentPSLanguageRes,
        S._2dc,
      ) as IPSLanguageRes)
    );
  }

  get contentType():
    | 'TEXT'
    | 'HTML'
    | 'JSON'
    | 'PROPERTIES'
    | 'USER'
    | 'USER2'
    | 'USER3'
    | 'USER4' {
    return this.M.contentType;
  }

  get dDContent(): string {
    return this.M.dDContent;
  }

  protected ddpslanguageres: IPSLanguageRes;
  getDDPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.ddpslanguageres ||
      (this.ddpslanguageres = this.fillObjectModel(
        S._276,
        this.M.getDDPSLanguageRes,
        S._367,
      ) as IPSLanguageRes)
    );
  }

  get iMContent(): string {
    return this.M.iMContent;
  }

  protected impslanguageres: IPSLanguageRes;
  getIMPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.impslanguageres ||
      (this.impslanguageres = this.fillObjectModel(
        S._276,
        this.M.getIMPSLanguageRes,
        S._368,
      ) as IPSLanguageRes)
    );
  }

  get mobTaskUrl(): string {
    return this.M.mobTaskUrl;
  }

  get sMSContent(): string {
    return this.M.sMSContent;
  }

  protected smspslanguageres: IPSLanguageRes;
  getSMSPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.smspslanguageres ||
      (this.smspslanguageres = this.fillObjectModel(
        S._276,
        this.M.getSMSPSLanguageRes,
        S._369,
      ) as IPSLanguageRes)
    );
  }

  protected subpslanguageres: IPSLanguageRes;
  getSubPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.subpslanguageres ||
      (this.subpslanguageres = this.fillObjectModel(
        S._276,
        this.M.getSubPSLanguageRes,
        S._36a,
      ) as IPSLanguageRes)
    );
  }

  get subject(): string {
    return this.M.subject;
  }

  get taskUrl(): string {
    return this.M.taskUrl;
  }

  get wXContent(): string {
    return this.M.wXContent;
  }

  protected wxpslanguageres: IPSLanguageRes;
  getWXPSLanguageRes(): IPSLanguageRes | null {
    return (
      this.wxpslanguageres ||
      (this.wxpslanguageres = this.fillObjectModel(
        S._276,
        this.M.getWXPSLanguageRes,
        S._36b,
      ) as IPSLanguageRes)
    );
  }

  get mailGroupSend(): boolean {
    return this.M.mailGroupSend;
  }
  get cls(): string {
    return 'PSSysMsgTemplImpl';
  }
  instanceof(cls: string): boolean {
    if (cls == S._271) return true;
    return super.instanceof(cls);
  }
}
